﻿using HomeWork.MODEL;

namespace HomeWork.IBLL
{
    public interface IActionBLL
    {
        /// <summary>
        /// 添加活动
        /// </summary>
        /// <param name="action">实体</param>
        /// <returns>受影响的行数</returns>
        Task<int> AddAciton(ActionInfo action);
        /// <summary>
        /// 活动列表
        /// </summary>
        /// <param name="ActionName">活动名称</param>
        /// <param name="ActionType">活动类型</param>
        /// <returns>符合条件的数据</returns>
        IQueryable<ActionInfo> GetActionsList(string? ActionName=null,string? ActionType=null);
        /// <summary>
        /// 反填活动
        /// </summary>
        /// <param name="ActionId">活动编号</param>
        /// <returns>符合条件的数据</returns>
        Task<ActionInfo> FindAction(int ActionId);
        /// <summary>
        /// 修改活动
        /// </summary>
        /// <param name="action">实体</param>
        /// <returns>受影响的行数</returns>
        Task<int> UpdateAction(ActionInfo action);
    }
}
